package com.ds.infrastructure.hyperspace.container.internal.http2;

import lombok.Getter;

import static io.netty.handler.codec.http2.Http2CodecUtil.DEFAULT_PRIORITY_WEIGHT;

/**
 * @author  Weishaoying
 */
@Getter
public class HyperspaceHttp2FlowControllerState {

    public static final HyperspaceHttp2FlowControllerState DEFAULT_FLOW_CONTROLLER_STATE =
            new HyperspaceHttp2FlowControllerState(0, DEFAULT_PRIORITY_WEIGHT, false);

    private int streamDependency;

    private short weight;

    private boolean exclusive;

    public HyperspaceHttp2FlowControllerState(int streamDependency, short weight, boolean exclusive) {
        this.streamDependency = streamDependency;
        this.weight = weight;
        this.exclusive = exclusive;
    }

}
